/*
 * Selling Partner API for Listings Items
 *
 * The Selling Partner API for Listings Items (Listings Items API) provides programmatic access to selling partner listings on Amazon. Use this API in collaboration with the Selling Partner API for Product Type Definitions, which you use to retrieve the information about Amazon product types needed to use the Listings Items API.  For more information, see the [Listings Items API Use Case Guide](https://developer-docs.amazon.com/sp-api/docs/listings-items-api-v2021-08-01-use-case-guide).
 *
 * The version of the OpenAPI document: 2021-08-01
 * Generated by: https://github.com/openapitools/openapi-generator.git
 */


using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = software.amzn.spapi.Client.OpenAPIDateConverter;

namespace software.amzn.spapi.Model.listings.items.v2021_08_01
{
    /// <summary>
    /// A variation theme that indicates the combination of listing item attributes that define the variation family.
    /// </summary>
    [DataContract(Name = "ItemVariationTheme")]
    public partial class ItemVariationTheme : IValidatableObject
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="ItemVariationTheme" /> class.
        /// </summary>
        [JsonConstructorAttribute]
        protected ItemVariationTheme() { }
        /// <summary>
        /// Initializes a new instance of the <see cref="ItemVariationTheme" /> class.
        /// </summary>
        /// <param name="attributes">The names of the listing item attributes that are associated with the variation theme. (required).</param>
        /// <param name="theme">The variation theme that indicates the combination of listing item attributes that define the variation family. (required).</param>
        public ItemVariationTheme(List<string> attributes = default(List<string>), string theme = default(string))
        {
            // to ensure "attributes" is required (not null)
            if (attributes == null)
            {
                throw new ArgumentNullException("attributes is a required property for ItemVariationTheme and cannot be null");
            }
            this.Attributes = attributes;
            // to ensure "theme" is required (not null)
            if (theme == null)
            {
                throw new ArgumentNullException("theme is a required property for ItemVariationTheme and cannot be null");
            }
            this.Theme = theme;
        }

        /// <summary>
        /// The names of the listing item attributes that are associated with the variation theme.
        /// </summary>
        /// <value>The names of the listing item attributes that are associated with the variation theme.</value>
        [DataMember(Name = "attributes", IsRequired = true, EmitDefaultValue = true)]
        public List<string> Attributes { get; set; }

        /// <summary>
        /// The variation theme that indicates the combination of listing item attributes that define the variation family.
        /// </summary>
        /// <value>The variation theme that indicates the combination of listing item attributes that define the variation family.</value>
        /*
        <example>COLOR_NAME/STYLE_NAME</example>
        */
        [DataMember(Name = "theme", IsRequired = true, EmitDefaultValue = true)]
        public string Theme { get; set; }

        /// <summary>
        /// Returns the string presentation of the object
        /// </summary>
        /// <returns>String presentation of the object</returns>
        public override string ToString()
        {
            StringBuilder sb = new StringBuilder();
            sb.Append("class ItemVariationTheme {\n");
            sb.Append("  Attributes: ").Append(Attributes).Append("\n");
            sb.Append("  Theme: ").Append(Theme).Append("\n");
            sb.Append("}\n");
            return sb.ToString();
        }

        /// <summary>
        /// Returns the JSON string presentation of the object
        /// </summary>
        /// <returns>JSON string presentation of the object</returns>
        public virtual string ToJson()
        {
            return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
        }

        /// <summary>
        /// To validate all properties of the instance
        /// </summary>
        /// <param name="validationContext">Validation context</param>
        /// <returns>Validation Result</returns>
        IEnumerable<ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
        {
            yield break;
        }
    }

}
